package com.mfg.service.Impl;

import com.mfg.mappers.WalletDetailsMapper;
import com.mfg.pojo.WalletDetails;
import com.mfg.service.WalletDetailsService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

@Service
public class WalletDetailsServiceImpl implements WalletDetailsService {

    @Resource
    private WalletDetailsMapper walletDetailsMapper;

    // 插入钱包详情
    public boolean insertWalletDetails(WalletDetails walletDetails) {
        return walletDetailsMapper.insertWalletDetails(walletDetails) > 0 ? true : false;
    }

    public List<WalletDetails> getWalletDetailsByWalletId(Integer walletId) {
        return walletDetailsMapper.getWalletDetailsByWalletId(walletId);
    }
}
